<!DOCTYPE html >
<html>
<head>
    <link rel="stylesheet" href="demos.css" type="text/css" media="screen" />

    <script src="/libraries/RGraph.common.core.js" ></script>
    <script src="/libraries/RGraph.scatter.js" ></script>
</head>
<body>

    <h1>A demo of the Chrome-only dotted or dashed background grid</h1>
    
    <p>
        This uses the relatively new Chrome only addition to canvas from the canvas v5 specification - native dotted and dashed lines.
        As browsers add support you will be able to use the option in them too but currently (May 2013) it's only supported in Chrome.
    </p>

    <pre class="code">
obj.Set('chart.background.grid.dashed', true);
obj.Set('chart.background.grid.dotted', true);
</pre>

    <canvas id="cvs1" width="600" height="250">[No canvas support]</canvas>
    <canvas id="cvs2" width="600" height="250">[No canvas support]</canvas>
    <script>
        scatter = new RGraph.Scatter('cvs1', [[50,50]])
            .Set('background.grid.dashed', true)
            .Set('xmax', 150)
            .Set('labels', ['Mal', 'Barry', 'Gary', 'Neil', 'Kim', 'Pete', 'Lou', 'Fred', 'Jobe'])
            .Set('background.grid.dashed', true)
            .Set('title', 'A dashed background grid')
            .Draw();

        scatter = new RGraph.Scatter('cvs2', [[50,50]])
            .Set('xmax', 150)
            .Set('labels', ['Mal', 'Barry', 'Gary', 'Neil', 'Kim', 'Pete', 'Lou', 'Fred', 'Jobe'])
            .Set('background.grid.dotted', true)
            .Set('title', 'A dotted background grid')
            .Draw();
    </script>

</body>
</html>